#include "Poller.h"
#include "Channel.h"

Poller::Poller(EventLoop *loop) : m_ownerLoop(loop)
{
}

// 判断参数Channel是否在当前Poller中
bool Poller::hasChannel(Channel *channel) const
{
    auto it = m_channelList.find(channel->getFd());
    return it != m_channelList.end() && it->second == channel;
}
